import React, { memo } from 'react'
import { 
    SearchInputWraper,
 } from "./style"

export default memo(function SearchInput(props) {
    return (
        <SearchInputWraper>
            <div className="icon">
                <i className='iconfont'>&#xe601;</i>
            </div>
            <input placeholder="音乐/视屏/电台/用户"
            // onChange={(e) => {console.log(e.target.value)}}
            onKeyDown={(e) => handlKeyBack(e)}
            />
        </SearchInputWraper>
    )

    function handlKeyBack(e) {
        // console.log(e.keyCode);
        if (e.keyCode === 13) {
            console.log('回车搜索');
        }
    }
})
